#include "Game.h"

namespace TUMAR { namespace CountryRoads {
	Game::Game(void) : State(Undefined)
	{
	}
	
	Game::~Game(void)
	{
	}

	double Game::GetElapsedTime() const
	{
		return (((double)cv::getTickCount() - this->StartTime) / cv::getTickFrequency());
	}

	double Game::GetTimeUntilMovementStart(void) const
	{
		return this->MovementStartTimeout - this->GetElapsedTime();
	}
	
	double Game::GetTimeUntilNextMovement(void) const
	{
		return this->MovementTimeout - (((double)cv::getTickCount() - this->LastMovementTime) / cv::getTickFrequency());
	}
}}